Creating the Collision Mesh
Creating the Collision meshes (work in Progress) There are easier ways to create collision meshes but this explains how everything works First, copy the standard mesh three times and name them col0, col1 and col2... col0 is used for projectiles, col1 for vehicles and col2 for soldiers. Optimize the collision meshes as needed. For example, stairs should be changed to ramps in the col2 mesh so they can be used in game. You should also remove some details that you don't need for the collision meshes. The collision meshes are invisible in-game. Notes: Col3 meshes are AImeshes and are not necessary unless you are creating Navmeshes. Hierarchy is called schematic in 3dsmax Now, it's time to set up your hierarchy, first create 4 dummy's clip_image001.jpg just click the dummy button like shown on the image above and drag it in your scene ( size and place don't matter). name the first dummy root_staticmesh_NAMEOFYOUROBJECT name the seccond geom0 name the third lod0 and last but not least, the fourth one name it nonvis_ now select your geom0 dummy and then push this button: clip_image002.jpg and then this button: clip_image002.jpg Now you can see your hierarchy with all your meshes and dummy's listed (except your geom0 because you've selected this one) Follow the steps shown in the next image: (note that in this image only shows one root dummy but yours you should show a lot more things). clip_image004.jpg Now its time to link all the other meshes and dummy's. The hierachy should look something like this when its done: clip_image005.jpg Check your progress by pushing this button clip_image003.jpg ... as long as this button isnt selected: clip_image002.jpg Thats it! You have just set up your first hierarchy. To set up textures, follow these steps: Right select your main mesh and hit the M button (for your material editor) and follow these steps: clip_image006.jpg Exporting the Collision mesh You can download the tool from http://rex3d.net/bf2/files/3dsmax/bf2_3dsmax_10Jun2006.zip The POE 3dsmax plugins are also useful: POE 3dsmax 9 tools Poe 3dsmax 6-8 tools A few export related problems suffer from a bad or missing setup of the tools, so here is some explanation. Make sure to have the tools installed correctly: get the .zip file with the latest tools and drag the folders from it into the /3DS Max folder on your system. You shouldn't copy the '_Max5' folder, unless you have 3dsmax 5. The '_BF2Help' folder is not strictly necessary, but contains some helpful documents when looking for the correct shadernames After launching 3DSmax run the BF2 Exporter and press 'Run Setup' in its window. A new window pops up , looking like this: Now fill in the values according to your setup. For this example, the BF2 game is installed in 'C:\Games\Battlefield 2\' if the mod is XWW2. The 'rawdata' path is included , 'BF2' and a testmod 'EFM' into the possible export pathes in the lower dialog. This is the most important step: Once the exporter finds one of these strings, it truncates the texture pathes (which are coded into the mesh) to a mod-relative path, meaning your object can run under any mod on any machine without hardcoded absolute pathes. In this case, the files are directly exporting into the mod structure. Some people prefer to use the /rawdata path (which is located in your /bf2editor folder ) as described in the official tutorials. After setting up the tool, push the finish setup button and you should now see something like this: At the objects sub-folder path type staticobjects/ or something like that. It doesn't really matter what you fill in, but, make sure that the path really exists cause else there wont be anything exported. Now its just simply a matter of pushing the 'export' button and if you've done everything right it should be in your mods/objects folder somewhere now. Just make sure that your textures are in the right folder (objects/staticobjects/yourobjectsname/textures/)